3.95 \(\int \frac{(f+g x)^2}{(a+b \log (c (d+e x)^n))^2} \, dx\)

Optimal. Leaf size=259 \[ \frac{4 g e^{-\frac{2 a}{b n}} (d+e x)^2 (e f-d g) \left (c (d+e x)^n\right )^{-2/n} \text{Ei}\left (\frac{2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right )}{b^2 e^3 n^2}+\frac{e^{-\frac{a}{b n}} (d+e x) (e f-d g)^2 \left (c (d+e x)^n\right )^{-1/n} \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right )}{b^2 e^3 n^2}+\frac{3 g^2 e^{-\frac{3 a}{b n}} (d+e x)^3 \left (c (d+e x)^n\right )^{-3/n} \text{Ei}\left (\frac{3 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right )}{b^2 e^3 n^2}-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )} \]

[Out]

((e*f - d*g)^2*(d + e*x)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])/(b*n)])/(b^2*e^3*E^(a/(b*n))*n^2*(c*(d + e*x
)^n)^n^(-1)) + (4*g*(e*f - d*g)*(d + e*x)^2*ExpIntegralEi[(2*(a + b*Log[c*(d + e*x)^n]))/(b*n)])/(b^2*e^3*E^((
2*a)/(b*n))*n^2*(c*(d + e*x)^n)^(2/n)) + (3*g^2*(d + e*x)^3*ExpIntegralEi[(3*(a + b*Log[c*(d + e*x)^n]))/(b*n)
])/(b^2*e^3*E^((3*a)/(b*n))*n^2*(c*(d + e*x)^n)^(3/n)) - ((d + e*x)*(f + g*x)^2)/(b*e*n*(a + b*Log[c*(d + e*x)
^n]))

________________________________________________________________________________________

Rubi [A]  time = 0.517006, antiderivative size = 259, normalized size of antiderivative = 1., number of steps used = 20, number of rules used = 7, integrand size = 24, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.292, Rules used = {2400, 2399, 2389, 2300, 2178, 2390, 2310} \[ \frac{4 g e^{-\frac{2 a}{b n}} (d+e x)^2 (e f-d g) \left (c (d+e x)^n\right )^{-2/n} \text{Ei}\left (\frac{2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right )}{b^2 e^3 n^2}+\frac{e^{-\frac{a}{b n}} (d+e x) (e f-d g)^2 \left (c (d+e x)^n\right )^{-1/n} \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right )}{b^2 e^3 n^2}+\frac{3 g^2 e^{-\frac{3 a}{b n}} (d+e x)^3 \left (c (d+e x)^n\right )^{-3/n} \text{Ei}\left (\frac{3 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right )}{b^2 e^3 n^2}-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )} \]

Antiderivative was successfully verified.

[In]

Int[(f + g*x)^2/(a + b*Log[c*(d + e*x)^n])^2,x]

[Out]

((e*f - d*g)^2*(d + e*x)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])/(b*n)])/(b^2*e^3*E^(a/(b*n))*n^2*(c*(d + e*x
)^n)^n^(-1)) + (4*g*(e*f - d*g)*(d + e*x)^2*ExpIntegralEi[(2*(a + b*Log[c*(d + e*x)^n]))/(b*n)])/(b^2*e^3*E^((
2*a)/(b*n))*n^2*(c*(d + e*x)^n)^(2/n)) + (3*g^2*(d + e*x)^3*ExpIntegralEi[(3*(a + b*Log[c*(d + e*x)^n]))/(b*n)
])/(b^2*e^3*E^((3*a)/(b*n))*n^2*(c*(d + e*x)^n)^(3/n)) - ((d + e*x)*(f + g*x)^2)/(b*e*n*(a + b*Log[c*(d + e*x)
^n]))

Rule 2400

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)*((f_.) + (g_.)*(x_))^(q_.), x_Symbol] :> Simp[((
d + e*x)*(f + g*x)^q*(a + b*Log[c*(d + e*x)^n])^(p + 1))/(b*e*n*(p + 1)), x] + (-Dist[(q + 1)/(b*n*(p + 1)), I
nt[(f + g*x)^q*(a + b*Log[c*(d + e*x)^n])^(p + 1), x], x] + Dist[(q*(e*f - d*g))/(b*e*n*(p + 1)), Int[(f + g*x
)^(q - 1)*(a + b*Log[c*(d + e*x)^n])^(p + 1), x], x]) /; FreeQ[{a, b, c, d, e, f, g, n}, x] && NeQ[e*f - d*g,
0] && LtQ[p, -1] && GtQ[q, 0]

Rule 2399

Int[((f_.) + (g_.)*(x_))^(q_.)/((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.)), x_Symbol] :> Int[ExpandIn
tegrand[(f + g*x)^q/(a + b*Log[c*(d + e*x)^n]), x], x] /; FreeQ[{a, b, c, d, e, f, g, n}, x] && NeQ[e*f - d*g,
 0] && IGtQ[q, 0]

Rule 2389

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.), x_Symbol] :> Dist[1/e, Subst[Int[(a + b*Log[c*
x^n])^p, x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, n, p}, x]

Rule 2300

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_), x_Symbol] :> Dist[x/(n*(c*x^n)^(1/n)), Subst[Int[E^(x/n)*(a +
b*x)^p, x], x, Log[c*x^n]], x] /; FreeQ[{a, b, c, n, p}, x]

Rule 2178

Int[(F_)^((g_.)*((e_.) + (f_.)*(x_)))/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[(F^(g*(e - (c*f)/d))*ExpIntegral
Ei[(f*g*(c + d*x)*Log[F])/d])/d, x] /; FreeQ[{F, c, d, e, f, g}, x] &&  !$UseGamma === True

Rule 2390

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_) + (g_.)*(x_))^(q_.), x_Symbol] :> Dist[1/
e, Subst[Int[((f*x)/d)^q*(a + b*Log[c*x^n])^p, x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p, q}, x]
 && EqQ[e*f - d*g, 0]

Rule 2310

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_)*((d_.)*(x_))^(m_.), x_Symbol] :> Dist[(d*x)^(m + 1)/(d*n*(c*x^n
)^((m + 1)/n)), Subst[Int[E^(((m + 1)*x)/n)*(a + b*x)^p, x], x, Log[c*x^n]], x] /; FreeQ[{a, b, c, d, m, n, p}
, x]

Rubi steps

\begin{align*} \int \frac{(f+g x)^2}{\left (a+b \log \left (c (d+e x)^n\right )\right )^2} \, dx &=-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{3 \int \frac{(f+g x)^2}{a+b \log \left (c (d+e x)^n\right )} \, dx}{b n}-\frac{(2 (e f-d g)) \int \frac{f+g x}{a+b \log \left (c (d+e x)^n\right )} \, dx}{b e n}\\ &=-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{3 \int \left (\frac{(e f-d g)^2}{e^2 \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{2 g (e f-d g) (d+e x)}{e^2 \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{g^2 (d+e x)^2}{e^2 \left (a+b \log \left (c (d+e x)^n\right )\right )}\right ) \, dx}{b n}-\frac{(2 (e f-d g)) \int \left (\frac{e f-d g}{e \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{g (d+e x)}{e \left (a+b \log \left (c (d+e x)^n\right )\right )}\right ) \, dx}{b e n}\\ &=-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{\left (3 g^2\right ) \int \frac{(d+e x)^2}{a+b \log \left (c (d+e x)^n\right )} \, dx}{b e^2 n}-\frac{(2 g (e f-d g)) \int \frac{d+e x}{a+b \log \left (c (d+e x)^n\right )} \, dx}{b e^2 n}+\frac{(6 g (e f-d g)) \int \frac{d+e x}{a+b \log \left (c (d+e x)^n\right )} \, dx}{b e^2 n}-\frac{\left (2 (e f-d g)^2\right ) \int \frac{1}{a+b \log \left (c (d+e x)^n\right )} \, dx}{b e^2 n}+\frac{\left (3 (e f-d g)^2\right ) \int \frac{1}{a+b \log \left (c (d+e x)^n\right )} \, dx}{b e^2 n}\\ &=-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{\left (3 g^2\right ) \operatorname{Subst}\left (\int \frac{x^2}{a+b \log \left (c x^n\right )} \, dx,x,d+e x\right )}{b e^3 n}-\frac{(2 g (e f-d g)) \operatorname{Subst}\left (\int \frac{x}{a+b \log \left (c x^n\right )} \, dx,x,d+e x\right )}{b e^3 n}+\frac{(6 g (e f-d g)) \operatorname{Subst}\left (\int \frac{x}{a+b \log \left (c x^n\right )} \, dx,x,d+e x\right )}{b e^3 n}-\frac{\left (2 (e f-d g)^2\right ) \operatorname{Subst}\left (\int \frac{1}{a+b \log \left (c x^n\right )} \, dx,x,d+e x\right )}{b e^3 n}+\frac{\left (3 (e f-d g)^2\right ) \operatorname{Subst}\left (\int \frac{1}{a+b \log \left (c x^n\right )} \, dx,x,d+e x\right )}{b e^3 n}\\ &=-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )}+\frac{\left (3 g^2 (d+e x)^3 \left (c (d+e x)^n\right )^{-3/n}\right ) \operatorname{Subst}\left (\int \frac{e^{\frac{3 x}{n}}}{a+b x} \, dx,x,\log \left (c (d+e x)^n\right )\right )}{b e^3 n^2}-\frac{\left (2 g (e f-d g) (d+e x)^2 \left (c (d+e x)^n\right )^{-2/n}\right ) \operatorname{Subst}\left (\int \frac{e^{\frac{2 x}{n}}}{a+b x} \, dx,x,\log \left (c (d+e x)^n\right )\right )}{b e^3 n^2}+\frac{\left (6 g (e f-d g) (d+e x)^2 \left (c (d+e x)^n\right )^{-2/n}\right ) \operatorname{Subst}\left (\int \frac{e^{\frac{2 x}{n}}}{a+b x} \, dx,x,\log \left (c (d+e x)^n\right )\right )}{b e^3 n^2}-\frac{\left (2 (e f-d g)^2 (d+e x) \left (c (d+e x)^n\right )^{-1/n}\right ) \operatorname{Subst}\left (\int \frac{e^{\frac{x}{n}}}{a+b x} \, dx,x,\log \left (c (d+e x)^n\right )\right )}{b e^3 n^2}+\frac{\left (3 (e f-d g)^2 (d+e x) \left (c (d+e x)^n\right )^{-1/n}\right ) \operatorname{Subst}\left (\int \frac{e^{\frac{x}{n}}}{a+b x} \, dx,x,\log \left (c (d+e x)^n\right )\right )}{b e^3 n^2}\\ &=\frac{e^{-\frac{a}{b n}} (e f-d g)^2 (d+e x) \left (c (d+e x)^n\right )^{-1/n} \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right )}{b^2 e^3 n^2}+\frac{4 e^{-\frac{2 a}{b n}} g (e f-d g) (d+e x)^2 \left (c (d+e x)^n\right )^{-2/n} \text{Ei}\left (\frac{2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right )}{b^2 e^3 n^2}+\frac{3 e^{-\frac{3 a}{b n}} g^2 (d+e x)^3 \left (c (d+e x)^n\right )^{-3/n} \text{Ei}\left (\frac{3 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right )}{b^2 e^3 n^2}-\frac{(d+e x) (f+g x)^2}{b e n \left (a+b \log \left (c (d+e x)^n\right )\right )}\\ \end{align*}

Mathematica [B]  time = 0.56144, size = 1015, normalized size = 3.92 \[ \frac{e^{-\frac{3 a}{b n}} \left (c (d+e x)^n\right )^{-3/n} \left (a e^2 e^{\frac{2 a}{b n}} f^2 (d+e x) \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right ) \left (c (d+e x)^n\right )^{2/n}+a d^2 e^{\frac{2 a}{b n}} g^2 (d+e x) \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right ) \left (c (d+e x)^n\right )^{2/n}-2 a d e e^{\frac{2 a}{b n}} f g (d+e x) \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right ) \left (c (d+e x)^n\right )^{2/n}+b e^2 e^{\frac{2 a}{b n}} f^2 (d+e x) \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right ) \log \left (c (d+e x)^n\right ) \left (c (d+e x)^n\right )^{2/n}+b d^2 e^{\frac{2 a}{b n}} g^2 (d+e x) \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right ) \log \left (c (d+e x)^n\right ) \left (c (d+e x)^n\right )^{2/n}-2 b d e e^{\frac{2 a}{b n}} f g (d+e x) \text{Ei}\left (\frac{a+b \log \left (c (d+e x)^n\right )}{b n}\right ) \log \left (c (d+e x)^n\right ) \left (c (d+e x)^n\right )^{2/n}-b e^3 e^{\frac{3 a}{b n}} g^2 n x^3 \left (c (d+e x)^n\right )^{3/n}-b d e^2 e^{\frac{3 a}{b n}} g^2 n x^2 \left (c (d+e x)^n\right )^{3/n}-2 b e^3 e^{\frac{3 a}{b n}} f g n x^2 \left (c (d+e x)^n\right )^{3/n}-b d e^2 e^{\frac{3 a}{b n}} f^2 n \left (c (d+e x)^n\right )^{3/n}-b e^3 e^{\frac{3 a}{b n}} f^2 n x \left (c (d+e x)^n\right )^{3/n}-2 b d e^2 e^{\frac{3 a}{b n}} f g n x \left (c (d+e x)^n\right )^{3/n}-4 a d e^{\frac{a}{b n}} g^2 (d+e x)^2 \text{Ei}\left (\frac{2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right ) \left (c (d+e x)^n\right )^{\frac{1}{n}}+4 a e e^{\frac{a}{b n}} f g (d+e x)^2 \text{Ei}\left (\frac{2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right ) \left (c (d+e x)^n\right )^{\frac{1}{n}}-4 b d e^{\frac{a}{b n}} g^2 (d+e x)^2 \text{Ei}\left (\frac{2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right ) \log \left (c (d+e x)^n\right ) \left (c (d+e x)^n\right )^{\frac{1}{n}}+4 b e e^{\frac{a}{b n}} f g (d+e x)^2 \text{Ei}\left (\frac{2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right ) \log \left (c (d+e x)^n\right ) \left (c (d+e x)^n\right )^{\frac{1}{n}}+3 a g^2 (d+e x)^3 \text{Ei}\left (\frac{3 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right )+3 b g^2 (d+e x)^3 \text{Ei}\left (\frac{3 \left (a+b \log \left (c (d+e x)^n\right )\right )}{b n}\right ) \log \left (c (d+e x)^n\right )\right )}{b^2 e^3 n^2 \left (a+b \log \left (c (d+e x)^n\right )\right )} \]

Antiderivative was successfully verified.

[In]

Integrate[(f + g*x)^2/(a + b*Log[c*(d + e*x)^n])^2,x]

[Out]

(-(b*d*e^2*E^((3*a)/(b*n))*f^2*n*(c*(d + e*x)^n)^(3/n)) - b*e^3*E^((3*a)/(b*n))*f^2*n*x*(c*(d + e*x)^n)^(3/n)
- 2*b*d*e^2*E^((3*a)/(b*n))*f*g*n*x*(c*(d + e*x)^n)^(3/n) - 2*b*e^3*E^((3*a)/(b*n))*f*g*n*x^2*(c*(d + e*x)^n)^
(3/n) - b*d*e^2*E^((3*a)/(b*n))*g^2*n*x^2*(c*(d + e*x)^n)^(3/n) - b*e^3*E^((3*a)/(b*n))*g^2*n*x^3*(c*(d + e*x)
^n)^(3/n) + a*e^2*E^((2*a)/(b*n))*f^2*(d + e*x)*(c*(d + e*x)^n)^(2/n)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])
/(b*n)] - 2*a*d*e*E^((2*a)/(b*n))*f*g*(d + e*x)*(c*(d + e*x)^n)^(2/n)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])
/(b*n)] + a*d^2*E^((2*a)/(b*n))*g^2*(d + e*x)*(c*(d + e*x)^n)^(2/n)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])/(
b*n)] + 4*a*e*E^(a/(b*n))*f*g*(d + e*x)^2*(c*(d + e*x)^n)^n^(-1)*ExpIntegralEi[(2*(a + b*Log[c*(d + e*x)^n]))/
(b*n)] - 4*a*d*E^(a/(b*n))*g^2*(d + e*x)^2*(c*(d + e*x)^n)^n^(-1)*ExpIntegralEi[(2*(a + b*Log[c*(d + e*x)^n]))
/(b*n)] + 3*a*g^2*(d + e*x)^3*ExpIntegralEi[(3*(a + b*Log[c*(d + e*x)^n]))/(b*n)] + b*e^2*E^((2*a)/(b*n))*f^2*
(d + e*x)*(c*(d + e*x)^n)^(2/n)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])/(b*n)]*Log[c*(d + e*x)^n] - 2*b*d*e*E
^((2*a)/(b*n))*f*g*(d + e*x)*(c*(d + e*x)^n)^(2/n)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])/(b*n)]*Log[c*(d +
e*x)^n] + b*d^2*E^((2*a)/(b*n))*g^2*(d + e*x)*(c*(d + e*x)^n)^(2/n)*ExpIntegralEi[(a + b*Log[c*(d + e*x)^n])/(
b*n)]*Log[c*(d + e*x)^n] + 4*b*e*E^(a/(b*n))*f*g*(d + e*x)^2*(c*(d + e*x)^n)^n^(-1)*ExpIntegralEi[(2*(a + b*Lo
g[c*(d + e*x)^n]))/(b*n)]*Log[c*(d + e*x)^n] - 4*b*d*E^(a/(b*n))*g^2*(d + e*x)^2*(c*(d + e*x)^n)^n^(-1)*ExpInt
egralEi[(2*(a + b*Log[c*(d + e*x)^n]))/(b*n)]*Log[c*(d + e*x)^n] + 3*b*g^2*(d + e*x)^3*ExpIntegralEi[(3*(a + b
*Log[c*(d + e*x)^n]))/(b*n)]*Log[c*(d + e*x)^n])/(b^2*e^3*E^((3*a)/(b*n))*n^2*(c*(d + e*x)^n)^(3/n)*(a + b*Log
[c*(d + e*x)^n]))

________________________________________________________________________________________

Maple [F]  time = 3.691, size = 0, normalized size = 0. \begin{align*} \int{\frac{ \left ( gx+f \right ) ^{2}}{ \left ( a+b\ln \left ( c \left ( ex+d \right ) ^{n} \right ) \right ) ^{2}}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((g*x+f)^2/(a+b*ln(c*(e*x+d)^n))^2,x)

[Out]

int((g*x+f)^2/(a+b*ln(c*(e*x+d)^n))^2,x)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} -\frac{e g^{2} x^{3} + d f^{2} +{\left (2 \, e f g + d g^{2}\right )} x^{2} +{\left (e f^{2} + 2 \, d f g\right )} x}{b^{2} e n \log \left ({\left (e x + d\right )}^{n}\right ) + b^{2} e n \log \left (c\right ) + a b e n} + \int \frac{3 \, e g^{2} x^{2} + e f^{2} + 2 \, d f g + 2 \,{\left (2 \, e f g + d g^{2}\right )} x}{b^{2} e n \log \left ({\left (e x + d\right )}^{n}\right ) + b^{2} e n \log \left (c\right ) + a b e n}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*x+f)^2/(a+b*log(c*(e*x+d)^n))^2,x, algorithm="maxima")

[Out]

-(e*g^2*x^3 + d*f^2 + (2*e*f*g + d*g^2)*x^2 + (e*f^2 + 2*d*f*g)*x)/(b^2*e*n*log((e*x + d)^n) + b^2*e*n*log(c)
+ a*b*e*n) + integrate((3*e*g^2*x^2 + e*f^2 + 2*d*f*g + 2*(2*e*f*g + d*g^2)*x)/(b^2*e*n*log((e*x + d)^n) + b^2
*e*n*log(c) + a*b*e*n), x)

________________________________________________________________________________________

Fricas [A]  time = 2.09722, size = 1025, normalized size = 3.96 \begin{align*} \frac{{\left (4 \,{\left (a e f g - a d g^{2} +{\left (b e f g - b d g^{2}\right )} n \log \left (e x + d\right ) +{\left (b e f g - b d g^{2}\right )} \log \left (c\right )\right )} e^{\left (\frac{b \log \left (c\right ) + a}{b n}\right )} \logintegral \left ({\left (e^{2} x^{2} + 2 \, d e x + d^{2}\right )} e^{\left (\frac{2 \,{\left (b \log \left (c\right ) + a\right )}}{b n}\right )}\right ) +{\left (a e^{2} f^{2} - 2 \, a d e f g + a d^{2} g^{2} +{\left (b e^{2} f^{2} - 2 \, b d e f g + b d^{2} g^{2}\right )} n \log \left (e x + d\right ) +{\left (b e^{2} f^{2} - 2 \, b d e f g + b d^{2} g^{2}\right )} \log \left (c\right )\right )} e^{\left (\frac{2 \,{\left (b \log \left (c\right ) + a\right )}}{b n}\right )} \logintegral \left ({\left (e x + d\right )} e^{\left (\frac{b \log \left (c\right ) + a}{b n}\right )}\right ) -{\left (b e^{3} g^{2} n x^{3} + b d e^{2} f^{2} n +{\left (2 \, b e^{3} f g + b d e^{2} g^{2}\right )} n x^{2} +{\left (b e^{3} f^{2} + 2 \, b d e^{2} f g\right )} n x\right )} e^{\left (\frac{3 \,{\left (b \log \left (c\right ) + a\right )}}{b n}\right )} + 3 \,{\left (b g^{2} n \log \left (e x + d\right ) + b g^{2} \log \left (c\right ) + a g^{2}\right )} \logintegral \left ({\left (e^{3} x^{3} + 3 \, d e^{2} x^{2} + 3 \, d^{2} e x + d^{3}\right )} e^{\left (\frac{3 \,{\left (b \log \left (c\right ) + a\right )}}{b n}\right )}\right )\right )} e^{\left (-\frac{3 \,{\left (b \log \left (c\right ) + a\right )}}{b n}\right )}}{b^{3} e^{3} n^{3} \log \left (e x + d\right ) + b^{3} e^{3} n^{2} \log \left (c\right ) + a b^{2} e^{3} n^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*x+f)^2/(a+b*log(c*(e*x+d)^n))^2,x, algorithm="fricas")

[Out]

(4*(a*e*f*g - a*d*g^2 + (b*e*f*g - b*d*g^2)*n*log(e*x + d) + (b*e*f*g - b*d*g^2)*log(c))*e^((b*log(c) + a)/(b*
n))*log_integral((e^2*x^2 + 2*d*e*x + d^2)*e^(2*(b*log(c) + a)/(b*n))) + (a*e^2*f^2 - 2*a*d*e*f*g + a*d^2*g^2
+ (b*e^2*f^2 - 2*b*d*e*f*g + b*d^2*g^2)*n*log(e*x + d) + (b*e^2*f^2 - 2*b*d*e*f*g + b*d^2*g^2)*log(c))*e^(2*(b
*log(c) + a)/(b*n))*log_integral((e*x + d)*e^((b*log(c) + a)/(b*n))) - (b*e^3*g^2*n*x^3 + b*d*e^2*f^2*n + (2*b
*e^3*f*g + b*d*e^2*g^2)*n*x^2 + (b*e^3*f^2 + 2*b*d*e^2*f*g)*n*x)*e^(3*(b*log(c) + a)/(b*n)) + 3*(b*g^2*n*log(e
*x + d) + b*g^2*log(c) + a*g^2)*log_integral((e^3*x^3 + 3*d*e^2*x^2 + 3*d^2*e*x + d^3)*e^(3*(b*log(c) + a)/(b*
n))))*e^(-3*(b*log(c) + a)/(b*n))/(b^3*e^3*n^3*log(e*x + d) + b^3*e^3*n^2*log(c) + a*b^2*e^3*n^2)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\left (f + g x\right )^{2}}{\left (a + b \log{\left (c \left (d + e x\right )^{n} \right )}\right )^{2}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*x+f)**2/(a+b*ln(c*(e*x+d)**n))**2,x)

[Out]

Integral((f + g*x)**2/(a + b*log(c*(d + e*x)**n))**2, x)

________________________________________________________________________________________

Giac [B]  time = 1.43274, size = 2755, normalized size = 10.64 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((g*x+f)^2/(a+b*log(c*(e*x+d)^n))^2,x, algorithm="giac")

[Out]

-(x*e + d)^3*b*g^2*n*e^3/(b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6) + 2*(x*e + d)^2*b*d*g
^2*n*e^3/(b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6) - (x*e + d)*b*d^2*g^2*n*e^3/(b^3*n^3*
e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6) + b*d^2*g^2*n*Ei(log(c)/n + a/(b*n) + log(x*e + d))*e^(
-a/(b*n) + 3)*log(x*e + d)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(1/n)) - 2*(x*e
+ d)^2*b*f*g*n*e^4/(b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6) + 2*(x*e + d)*b*d*f*g*n*e^4
/(b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6) - 2*b*d*f*g*n*Ei(log(c)/n + a/(b*n) + log(x*e
 + d))*e^(-a/(b*n) + 4)*log(x*e + d)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(1/n))
 - 4*b*d*g^2*n*Ei(2*log(c)/n + 2*a/(b*n) + 2*log(x*e + d))*e^(-2*a/(b*n) + 3)*log(x*e + d)/((b^3*n^3*e^6*log(x
*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(2/n)) + b*d^2*g^2*Ei(log(c)/n + a/(b*n) + log(x*e + d))*e^(-a
/(b*n) + 3)*log(c)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(1/n)) - (x*e + d)*b*f^2
*n*e^5/(b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6) + a*d^2*g^2*Ei(log(c)/n + a/(b*n) + log
(x*e + d))*e^(-a/(b*n) + 3)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(1/n)) + b*f^2*
n*Ei(log(c)/n + a/(b*n) + log(x*e + d))*e^(-a/(b*n) + 5)*log(x*e + d)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6
*log(c) + a*b^2*n^2*e^6)*c^(1/n)) + 4*b*f*g*n*Ei(2*log(c)/n + 2*a/(b*n) + 2*log(x*e + d))*e^(-2*a/(b*n) + 4)*l
og(x*e + d)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(2/n)) + 3*b*g^2*n*Ei(3*log(c)/
n + 3*a/(b*n) + 3*log(x*e + d))*e^(-3*a/(b*n) + 3)*log(x*e + d)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c
) + a*b^2*n^2*e^6)*c^(3/n)) - 2*b*d*f*g*Ei(log(c)/n + a/(b*n) + log(x*e + d))*e^(-a/(b*n) + 4)*log(c)/((b^3*n^
3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(1/n)) - 4*b*d*g^2*Ei(2*log(c)/n + 2*a/(b*n) + 2*lo
g(x*e + d))*e^(-2*a/(b*n) + 3)*log(c)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(2/n)
) - 2*a*d*f*g*Ei(log(c)/n + a/(b*n) + log(x*e + d))*e^(-a/(b*n) + 4)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*
log(c) + a*b^2*n^2*e^6)*c^(1/n)) - 4*a*d*g^2*Ei(2*log(c)/n + 2*a/(b*n) + 2*log(x*e + d))*e^(-2*a/(b*n) + 3)/((
b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(2/n)) + b*f^2*Ei(log(c)/n + a/(b*n) + log(x*
e + d))*e^(-a/(b*n) + 5)*log(c)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(1/n)) + 4*
b*f*g*Ei(2*log(c)/n + 2*a/(b*n) + 2*log(x*e + d))*e^(-2*a/(b*n) + 4)*log(c)/((b^3*n^3*e^6*log(x*e + d) + b^3*n
^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(2/n)) + 3*b*g^2*Ei(3*log(c)/n + 3*a/(b*n) + 3*log(x*e + d))*e^(-3*a/(b*n) +
3)*log(c)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(3/n)) + a*f^2*Ei(log(c)/n + a/(b
*n) + log(x*e + d))*e^(-a/(b*n) + 5)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(1/n))
 + 4*a*f*g*Ei(2*log(c)/n + 2*a/(b*n) + 2*log(x*e + d))*e^(-2*a/(b*n) + 4)/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2
*e^6*log(c) + a*b^2*n^2*e^6)*c^(2/n)) + 3*a*g^2*Ei(3*log(c)/n + 3*a/(b*n) + 3*log(x*e + d))*e^(-3*a/(b*n) + 3)
/((b^3*n^3*e^6*log(x*e + d) + b^3*n^2*e^6*log(c) + a*b^2*n^2*e^6)*c^(3/n))